<!--#include file="AspCms_AdminGroupFun.asp" -->
<%CheckAdmin("AspCms_AdminGroupList.asp")%>
<html lang="zh-CN" style="min-height: 100%;">
<head>
<title>AdminGroupAdd</title>
<meta charset="utf-8">
<meta name="viewport" content="width=device-width, initial-scale=1, maximum-scale=1, user-scalable=no">
<meta name="renderer" content="webkit">
<meta http-equiv="X-UA-Compatible" content="IE=edge,Chrome=1" />

<link href="https://cdn.bootcss.com/uikit/3.0.0-beta.22/css/uikit.min.css" rel="stylesheet">
<link href="https://cdn.bootcss.com/jquery.perfect-scrollbar/0.7.0/css/perfect-scrollbar.min.css" rel="stylesheet">
<link href="../../css/timoo/fancySelect.css" rel="stylesheet">
<link href="../../css/timoo/timoo.css" rel="stylesheet">

<script src="https://cdn.bootcss.com/jquery/3.2.1/jquery.min.js"></script>
<script src="../../ueditor/ueditor.config.js"></script>
<script src="../../ueditor/ueditor.all.min.js"> </script>
<script src="../../ueditor/lang/zh-cn/zh-cn.js"></script>
<script src="https://cdn.bootcss.com/uikit/3.0.0-beta.22/js/uikit.min.js"></script>
<script src="https://cdn.bootcss.com/uikit/3.0.0-beta.22/js/uikit-icons.min.js"></script>
<script src="https://cdn.bootcss.com/jquery.perfect-scrollbar/0.7.0/js/perfect-scrollbar.jquery.min.js"></script>
<script src="../../js/timoo/icheck.min.js"></script>
<script src="../../js/timoo/fancySelect.js"></script>
<script src="../../js/timoo/timoo.js"></script>
</head>
<body>
<div class="tm-right">
    <div class="main">
        <div class="section setting-company user">
            <form name="form" action="?action=addg" method="post">
                <div class="layout">
                    <div class="title">添加管理员组</div>
                    <div class="content">
                        <div class="tm-transition list">
                            <div class="uk-clearfix tm-transition subject">
                                <span class="uk-float-left">管理员组名称</span>
                                <i class="tm-transition icon" uk-icon="icon: info" uk-tooltip="pos: right" title="管理员组的名称。"></i>
                            </div>
                            <div class="input">
                                <input type="text" maxLength="200" name="GroupName">
                            </div>
                        </div>
                        <div class="tm-transition textarea list">
                            <div class="uk-clearfix tm-transition subject">
                                <span class="uk-float-left">管理员组描述</span>
                            </div>
                            <div class="input">
                                <textarea type="text" name="GroupDesc"></textarea>
                            </div>
                        </div>
                        <div class="tm-transition checkbox list">
                            <div class="uk-clearfix tm-transition subject">
                                <span class="uk-float-left">是否启用</span>
                            </div>
                            <div class="uk-clearfix input">
                                <label for="Group-Admin-Status" class="uk-clearfix uk-float-left tm-transition">
                                    <span class="uk-float-left check">
                                        <i class="tm-transition icon" uk-icon="icon: check"></i>
                                    </span>
                                    <span class="uk-float-left">启用</span>
                                    <input id="Group-Admin-Status" type="checkbox" checked="checked" name="GroupStatus" value="1">
                                </label>
                            </div>
                        </div>
                        <div class="tm-transition list">
                            <div class="uk-clearfix tm-transition subject">
                                <span class="uk-float-left">管理员组权限</span>
                            </div>
                            <div class="input">
                                <input type="text" size="11" name="GroupMark" value="0">
                            </div>
                        </div>
                        <div class="tm-transition list">
                            <div class="uk-clearfix tm-transition subject">
                                <span class="uk-float-left">管理员组排序</span>
                            </div>
                            <div class="input">
                                <input type="text" size="11" value="0" name="GroupOrder">
                            </div>
                        </div>
                    </div>
                </div>
                <div class="layout power">
                    <div class="title">权限分配</div>
                    <div class="content">
                        <%
                            dim rs,subrs
                            set rs=conn.exec("select MenuID, MenuName, (select Count(*) from {prefix}Menu as b where MenuStatus=1 and b.ParentID=a.MenuID ) from {prefix}Menu as a where MenuStatus=1 and ParentID=0 order by MenuOrder","r1")

                            do while not rs.eof 
                        %>
                        <div class="tm-transition input checkbox list">
                            <div class="uk-clearfix power-list">
                                <div class="uk-clearfix power-group">
                                    <label for="Power-Group-<%=rs(0) %>" class="uk-clearfix uk-float-left tm-transition">
                                        <span class="uk-float-left check">
                                            <i class="tm-transition icon" uk-icon="icon: check"></i>
                                        </span>
                                        <span class="uk-float-left"><%=rs(1) %></span>
                                        <input id="Power-Group-<%=rs(0) %>" type="checkbox" name="GroupMenu" value="<%=rs(0) %>">
                                    </label>
                                </div>
                                <div class="power-unit">
                                    <ul class="uk-clearfix">
                                        <%
                                            set subrs=conn.exec("select MenuID, MenuName from {prefix}Menu where MenuStatus=1 and ParentID="&rs(0)&" order by MenuOrder","r1")
                                            
                                            do while not subrs.eof
                                        %>
                                        <li class="uk-float-left">
                                            <label for="Power-Unit-<%=subrs(0) %>" class="uk-clearfix uk-float-left tm-transition">
                                                <span class="uk-float-left check">
                                                    <i class="tm-transition icon" uk-icon="icon: check"></i>
                                                </span>
                                                <span class="uk-float-left"><%=subrs(1) %></span>
                                                <input id="Power-Unit-<%=subrs(0) %>" type="checkbox" name="GroupMenu" value="<%=subrs(0) %>">
                                            </label>
                                        </li>
                                        <%
                                            subrs.moveNext
                                            loop
                                        %>
                                    </ul>
                                </div>
                            </div>
                        </div>
                        <%
                            rs.moveNext
                            loop
                        %>
                    </div>
                </div>
                <div class="layout">
                    <div class="title">保存更改</div>
                    <div class="content">
                        <div class="uk-clearfix tm-transition list submit">
                            <div class="uk-float-left input">
                                <input type="submit" value="添加">
                            </div>
                            <div class="uk-float-left input">
                                <input type="button" value="返回" onClick="history.go(-1)"> 
                            </div>
                        </div>
                    </div>
                </div>
            </form>
        </div>
    </div>
</div>
</body>
</html>